Vmgen | a Generator of Eecient Virtual Machine Interpreters

نویسندگان

  • M. Anton Ertl
  • David Gregg
  • Andreas Krall
  • Bernd Paysan
چکیده

Machine Interpreters M. Anton Ertl1; ;y, David Gregg2, Andreas Krall1, and Bernd Paysan3 1Institut f ur Computersprachen, Technische Universit at Wien, Argentinierstra e 8, A-1040 Wien, Austria 2Department of Computer Science, Trinity College, Dublin 2, Ireland 3Stockmannstr. 14, D-81477 M unchen, Germany SUMMARY In a virtual machine interpreter, the code for each virtual machine instruction has similarities to code for other instructions. We present an interpreter generator that takes simple virtual machine instruction descriptions as input and generates C code for processing the instructions in several ways: execution, virtual machine code generation, disassembly, tracing, and pro ling. The generator is designed to support e cient interpreters: it supports threaded code, caching the top-of-stack item in a register, combining simple instructions into superinstructions, and other optimizations. We have used the generator to create interpreters for Forth and Java. The resulting interpreters are faster than other interpreters for the same languages and they are typically 2{10 times slower than code produced by native-code compilers. We also present results for the e ects of the individual optimizations supported by the generator.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Vmgen - a generator of efficient virtual machine interpreters

In a virtual machine interpreter, the code for each virtual machine instruction has similarities to code for other instructions. We present an interpreter generator that takes simple virtual machine instruction descriptions as input and generates C code for processing the instructions in several ways: execution, virtual machine code generation, disassembly, tracing, and profiling. The generator...

متن کامل

The Behavior of Eecient Virtual Machine Interpreters on Modern Architectures

Romer et al (ASPLOS 96) examined several interpreters and concluded that they behave much like general purpose integer programs such as gcc. We show that there is an important class of interpreters which behave very diierently. EEcient virtual machine interpreters perform a large number of indirect branches (3.2%{13% of all executed instructions in our benchmarks, taking up to 61%-79% of the cy...

متن کامل

Building an Interpreter with Vmgen

Vmgen automates many of the tasks of writing the virtual machine part of an interpreter, resulting in less coding, debugging and maintenance eeort. This paper gives some quantitative data about the source code and generated code for a vmgen-based interpreter, and gives some examples demonstrating the simplicity of using vmgen.

متن کامل

Implementing an Eecient Java Interpreter

The Java virtual machine (JVM) is usually implemented with an interpreter or just-in-time (JIT) compiler. JIT compilers provide the best performance, but must be substantially rewritten for each architecture they are ported to. Interpreters are easier to develop and maintain, and can be ported to new architectures with almost no changes. The weakness of interpreters is that they are much slower...

متن کامل

Tiger - An Interpreter Generation Tool

Tiger (Trinity Interpreter GEneratoR) is a new interpreter generator tool along the lines of vmgen, but with significant improvements in flexibility and feedback. Support for important new features such as instruction specialisation, replication and improved analysis of code at runtime are presented. A simple ‘C’ virtual machine imported into Tiger is used for demonstration purposes. Various re...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2001